package com.hcxdi.api.bean.user;

import android.os.Parcel;
import android.os.Parcelable;

/**
 * Created by jiajiabao on 16-11-11.
 */

public class User implements Parcelable {
    private String rewardAmount;
    private boolean idChecked;
    private Truck currentTruck;
    private String reg;
    private String scores;
    private String phone;
    private String feedbackCount;
    private String nickname;
    private String realname;
    private String recommendUser;
    private String orders;
    private int truckCount;
    private String headerImg;
    private String  idNo;
    private String lockedTotalScore;
    private int usertype;

    public String getRewardAmount() {
        return rewardAmount;
    }

    public void setRewardAmount(String rewardAmount) {
        this.rewardAmount = rewardAmount;
    }

    public String getHeaderImg() {
        return headerImg;
    }

    public void setHeaderImg(String headerImg) {
        this.headerImg = headerImg;
    }

    public boolean isIdChecked() {
        return idChecked;
    }

    public void setIdChecked(boolean idChecked) {
        this.idChecked = idChecked;
    }

    public Truck getCurrentTruck() {
        return currentTruck;
    }

    public void setCurrentTruck(Truck currentTruck) {
        this.currentTruck = currentTruck;
    }

    public String getReg() {
        return reg;
    }

    public void setReg(String reg) {
        this.reg = reg;
    }

    public String getScores() {
        return scores;
    }

    public void setScores(String scores) {
        this.scores = scores;
    }

    public String getPhone() {
        return phone;
    }

    public void setPhone(String phone) {
        this.phone = phone;
    }

    public String getFeedbackCount() {
        return feedbackCount;
    }

    public void setFeedbackCount(String feedbackCount) {
        this.feedbackCount = feedbackCount;
    }

    public String getNickname() {
        return nickname;
    }

    public void setNickname(String nickname) {
        this.nickname = nickname;
    }

    public String getRealname() {
        return realname;
    }

    public void setRealname(String realname) {
        this.realname = realname;
    }

    public String getRecommendUser() {
        return recommendUser;
    }

    public void setRecommendUser(String recommendUser) {
        this.recommendUser = recommendUser;
    }

    public String getOrders() {
        return orders;
    }

    public void setOrders(String orders) {
        this.orders = orders;
    }

    public int getTruckCount() {
        return truckCount;
    }

    public void setTruckCount(int truckCount) {
        this.truckCount = truckCount;
    }

    public String getIdNo() {
        return idNo;
    }

    public void setIdNo(String idNo) {
        this.idNo = idNo;
    }

    public String getLockedTotalScore() {
        return lockedTotalScore;
    }

    public void setLockedTotalScore(String lockedTotalScore) {
        this.lockedTotalScore = lockedTotalScore;
    }

    public int getUsertype() {
        return usertype;
    }

    public void setUsertype(int usertype) {
        this.usertype = usertype;
    }

    public static Creator<User> getCREATOR() {
        return CREATOR;
    }

    @Override
    public int describeContents() {
        return 0;
    }

    @Override
    public void writeToParcel(Parcel dest, int flags) {
        dest.writeString(this.rewardAmount);
        dest.writeByte(this.idChecked ? (byte) 1 : (byte) 0);
        dest.writeParcelable(this.currentTruck, flags);
        dest.writeString(this.reg);
        dest.writeString(this.scores);
        dest.writeString(this.phone);
        dest.writeString(this.feedbackCount);
        dest.writeString(this.nickname);
        dest.writeString(this.realname);
        dest.writeString(this.recommendUser);
        dest.writeString(this.orders);
        dest.writeInt(this.truckCount);
        dest.writeString(this.headerImg);
        dest.writeString(this.idNo);
        dest.writeString(this.lockedTotalScore);
        dest.writeInt(this.usertype);
    }

    public User() {
    }

    protected User(Parcel in) {
        this.rewardAmount = in.readString();
        this.idChecked = in.readByte() != 0;
        this.currentTruck = in.readParcelable(Truck.class.getClassLoader());
        this.reg = in.readString();
        this.scores = in.readString();
        this.phone = in.readString();
        this.feedbackCount = in.readString();
        this.nickname = in.readString();
        this.realname = in.readString();
        this.recommendUser = in.readString();
        this.orders = in.readString();
        this.truckCount = in.readInt();
        this.headerImg = in.readString();
        this.idNo = in.readString();
        this.lockedTotalScore = in.readString();
        this.usertype = in.readInt();
    }

    public static final Parcelable.Creator<User> CREATOR = new Parcelable.Creator<User>() {
        @Override
        public User createFromParcel(Parcel source) {
            return new User(source);
        }

        @Override
        public User[] newArray(int size) {
            return new User[size];
        }
    };
}
